package arrays

// IncludesBy 判断数组中是否有元素满足指定的条件
func IncludesBy[T any](array []T, fn func(T, int, []T) bool) bool {
	for i, v := range array {
		if fn(v, i, array) {
			return true
		}
	}
	return false
}
